package com.mugu.yunying.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.mugu.yunying.mapper.PhoneCodeMapper;
import com.mugu.yunying.domain.PhoneCode;
import com.mugu.yunying.service.IPhoneCodeService;

/**
 * 手机验证码Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-03-27
 */
@Service
public class PhoneCodeServiceImpl implements IPhoneCodeService 
{
    @Autowired
    private PhoneCodeMapper phoneCodeMapper;

    /**
     * 查询手机验证码
     * 
     * @param id 手机验证码ID
     * @return 手机验证码
     */
    @Override
    public PhoneCode selectPhoneCodeById(Integer id)
    {
        return phoneCodeMapper.selectPhoneCodeById(id);
    }

    /**
     * 查询手机验证码列表
     * 
     * @param phoneCode 手机验证码
     * @return 手机验证码
     */
    @Override
    public List<PhoneCode> selectPhoneCodeList(PhoneCode phoneCode)
    {
        return phoneCodeMapper.selectPhoneCodeList(phoneCode);
    }

    /**
     * 新增手机验证码
     * 
     * @param phoneCode 手机验证码
     * @return 结果
     */
    @Override
    public int insertPhoneCode(PhoneCode phoneCode)
    {
        return phoneCodeMapper.insertPhoneCode(phoneCode);
    }

    /**
     * 修改手机验证码
     * 
     * @param phoneCode 手机验证码
     * @return 结果
     */
    @Override
    public int updatePhoneCode(PhoneCode phoneCode)
    {
        return phoneCodeMapper.updatePhoneCode(phoneCode);
    }

    /**
     * 批量删除手机验证码
     * 
     * @param ids 需要删除的手机验证码ID
     * @return 结果
     */
    @Override
    public int deletePhoneCodeByIds(Integer[] ids)
    {
        return phoneCodeMapper.deletePhoneCodeByIds(ids);
    }

    /**
     * 删除手机验证码信息
     * 
     * @param id 手机验证码ID
     * @return 结果
     */
    @Override
    public int deletePhoneCodeById(Integer id)
    {
        return phoneCodeMapper.deletePhoneCodeById(id);
    }
}
